package com.scapegoat.pay.account.service.api.impl;

import java.util.HashMap;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.scapegoat.pay.common.core.page.PageBean;
import com.scapegoat.pay.common.core.page.PageParam;
import com.scapegoat.pay.account.service.api.RpAccountHistoryService;
import com.scapegoat.pay.account.service.dao.RpAccountHistoryDao;
import com.scapegoat.pay.account.service.entity.RpAccountHistory;

/**
 * 账户历史service实现类
 *
 * @author walkman
 * @date 2017年10月17日 21:19:33
 */
@Service("rpAccountHistoryService")
public class RpAccountHistoryServiceImpl implements RpAccountHistoryService {

    @Autowired
    private RpAccountHistoryDao rpAccountHistoryDao;

    @Override
    public void saveData(RpAccountHistory rpAccountHistory) {
        rpAccountHistoryDao.insert(rpAccountHistory);
    }

    @Override
    public void updateData(RpAccountHistory rpAccountHistory) {
        rpAccountHistoryDao.update(rpAccountHistory);
    }

    @Override
    public RpAccountHistory getDataById(String id) {
        return rpAccountHistoryDao.getById(id);
    }

    @Override
    public PageBean listPage(PageParam pageParam, RpAccountHistory rpAccountHistory) {
        Map<String, Object> paramMap = new HashMap<String, Object>();
        return rpAccountHistoryDao.listPage(pageParam, paramMap);
    }
}